<%Const respagecode="system_msgs_edit"%><% 'UTF-8%>
<%''加载通用函数和数据库连接%>
<!--#include file="../Include/Start.asp"-->
<%'检查是否登录%>
<!--#include file="../Include/checklogin.asp"-->

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
	<!--meta信息-->
	<!--#include file="../Include/meta.asp"-->
	
	
	<link href="../css/css-1.05.css" rel="stylesheet" type="text/css" />
	<link href="../css/console-1.03.css" rel="stylesheet" type="text/css" />
	<link href="../css/calendar.css" rel="stylesheet" type="text/css" />
	<link href="../css/console_home-1.06.css" rel="stylesheet" type="text/css" />
	
	<script type="text/javascript" src="../js/jquery-1.3.2.js"></script>
	<script type="text/javascript" src="../js/jquery.extend-1.06.js"></script>
	<script type="text/javascript" src="../js/common_1.01.js"></script>
	<script type="text/javascript" src="../js/console_msgs.js"></script>
	<script type="text/javascript" src="../js/calendar/WdatePicker.js"></script>
	<script type="text/javascript" src="../js/menu.js"></script>
	<script type="text/javascript" src="../js/TrimPathTemplate.js"></script>
	<!--Html编辑器-->
	<script type="text/javascript" src="../js/ckeditor/ckeditor_basic.js"></script>

</head>

<body>
<div class="wrapper">

	<!--header页头信息-->
	<!--#include file="../Include/header.asp"-->
	<!--end header页头信息-->


	<!--navigation菜单信息-->
	<!--#include file="../Include/navigation.asp"-->
	<script type="text/javascript">$("#navigation").menu('point');</script>
	<!--end navigation菜单信息-->

<!--begin container-->
<div class="container" id="container">
 
	
	<div class="c_left">
		<h2>控制台</h2>
		<ul>
			<li class="on"><h3><a href="/console/msgs.asp">发布信息维护</a></h3></li>
		</ul>
	</div>
	<div class="c_right">
		<div class="c_r_head">
			<ul class="head_tab">
				<li><h4><a href="msgs.asp##div_tab_list">发布信息维护</a></h4></li>
				<li class="on"><h4><a href="#">修改</a></h4></li>
				<li><h4><a href="msgs.asp##div_tab_add">新增</a></h4></li>
			</ul>
		</div>	
		<%
	 	''定义查询字段变量
	dim id, sendtime, sender, title, incept, content, tag ,tagcode
			
''用户信息
		id=ReplaceBadChar(Trim(request("id")))
			if(""=id) then response.redirect "/msgs.asp" ''如果id并没有传来跳转回原处
			''Dim rsObj,strSql
			set rsObj=Server.CreateObject("ADODB.Recordset")
			strSql = "Select  *  "
  		strSql=strSql & "  from T_MSG where id='"&id&"' "
			''Response.Write strSql&"-----"
			rsObj.Open strSql, Conn, 1, 3
			If rsObj.BOF And rsObj.EOF Then 
				 response.redirect "/msgs.asp" ''如果id并没有传来跳转回原处
			end if	 
			id=Trim(rsObj("id"))
			sendtime=Trim(rsObj("sendtime"))
			sender=Trim(rsObj("sender"))
			title=Trim(rsObj("title"))
			incept=Trim(rsObj("incept"))
			tagcode=Trim(rsObj("tagcode"))
			tag=Trim(rsObj("tag"))
			content=rsObj("content")
			''Response.Write res_name&"-----" 
			''关闭链接
			rsObj.close		

	%>	
		
		<div class="c_r_body" id="div_tab_edit">
			<form action="msgs_do.asp?act=edit" method="post" id="form_edit">
				<input id="id" name="id" type="hidden" value="<%=id%>" />
			<div align="center" style="height:25px">
				请输入发布信息
			</div>
				<table width="100%" border="0" cellpadding="2" cellspacing="4" style="margin:auto">
		 
					<tr>
						<td align="right">标题:</td>
						<td><input type="text" name="title" id="title"  value="<%=title%>" class="text" style="width:100px" maxlength="50" /></td>
						<td align="right">摘要:</td>
						<td><input type="text" name="incept" id="incept"  value="<%=incept%>" class="text" style="width:100px" maxlength="50" /></td>
					</tr>
					<tr>
						<td align="right">分类:</td>
						<td><input type="text" name="tag" id="tag"  value="<%=tag%>" class="text" style="width:100px" maxlength="50" /></td>
						<td align="right">分类编码:</td>
						<td><input type="text" name="tagcode" id="tagcode"  value="<%=tagcode%>" class="text" style="width:100px" maxlength="50" /></td>
					</tr>
					<tr>
						<td align="right">内容:</td>
						<td><input name="" type="submit" value="修改保存" />&nbsp;<label id="result"></label></td>
						<td align="right">修改时间:</td>
						<td><%=sendtime%></td>
					</tr>
 
					<tr>
						<td colspan="4" align="right">
							<textarea class="ckeditor" cols="200"  name="msg_content" id="msg_content" rows="10"><%=content%></textarea>
						</td>
					</tr>
 				
					
				</table>
			</form>
		</div>
	</div>

	<script type="text/javascript">
		/*选中该tab页 需要tab页上有ID*/
		$("#index").attr("className","on")
		
		//initPage_edit();	
		//$('#scform').submit();
	</script>
	
 
 
</div> 
	
	
</div>
<!--footer页脚信息-->
<!--#include file="../Include/footer.asp"-->
<!--end footer页脚信息-->
</div>
</body>
</html>

<%
			Set rsObj = Nothing 

 '释放数据库链接
	call CloseConn	
	%>	
